﻿using System;
using System.Windows;
using CommandLine;

namespace TwitterBand
{
    public partial class App : Application
    {
        private string[] args;

        protected override void OnStartup(StartupEventArgs e) {
            args = e.Args;
        }

        protected override void OnActivated(EventArgs e) {
            var commandLineParser = new CommandLineParser();
            var options = new Options();
            var parsedSuccessfull = commandLineParser.ParseArguments(args, options);
            if (!parsedSuccessfull) {
                MessageBox.Show("");
            }

            ((MainWindow)MainWindow).Fenster_konfigurieren(options.AlwaysOnTop);
            ((MainWindow)MainWindow).Suchbegriff_festlegen(options.Query);
        }
    }
}